package com.fireandsword.system.enums;

import com.fireandsword.system.domain.vo.StatusCode;
import lombok.Getter;

/**
 * @author Immortal
 * @version 1.0
 * @description TODO
 * @date 2023/12/27 14:33
 */
@Getter
public enum ResultCode implements StatusCode{

    SUCCESS(200, "成功"),
    FAIL(500, "失败"),
    PARAM_ERROR(400, "参数错误"),
    NOT_FOUND(404, "未找到"),
    UNAUTHORIZED(401, "未授权"),
    FORBIDDEN(403, "禁止访问"),
    NOT_SUPPORT(406, "不支持"),
    SERVER_ERROR(500, "服务器错误");

    private Integer code;

    private String msg;

    ResultCode(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }
}
